View Javadoc
1   /*
2    * ListProperties.java
3    *
4    * Created on December 20, 2004, 3:40 PM
5    */
6   
7   package gov.noaa.eds.xapi.generic;
8   
9   import java.util.Hashtable;
10  import org.xmldb.api.base.Configurable;
11  
12  /***
13   * Base Implementation of Configurable.
14   * @author tns
15   * @version $Id: GenericConfigurable.java,v 1.2 2004/12/23 22:26:01 mrxtravis Exp $
16   */
17  public class GenericConfigurable implements Configurable {
18      
19      protected Hashtable properties = new Hashtable();
20      
21      /*** Creates a new instance of ListProperties */
22      public GenericConfigurable() {
23      }
24  
25      /*** Retrieve a property value 
26       *@param prop The property value to retrieve
27       */
28      public String getProperty(String prop) {
29          return (String) properties.get(prop);
30      }
31  
32      /*** Set a property value
33       *@param prop The property to set
34       *@param value The value of the property
35       */
36      public void setProperty(String prop, String value) {
37          properties.put(prop,value);
38      }
39      
40  }